package com.example.infrastructure.persistence.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.example.infrastructure.common.BasePO;
import java.io.Serializable;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 问诊消息表 PO
 *
 * @author wangal
 * @since 2025-07-25
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("consultation_messages")
@Schema(name = "ConsultationMessages", description = "问诊消息表")
public class ConsultationMessages extends BasePO {

    private static final long serialVersionUID = 1L;

    @Schema(description = "问诊ID")
    @TableField("consultation_id")
    private Long consultationId;

    @Schema(description = "发送者类型：1患者，2医生")
    @TableField("sender_type")
    private Byte senderType;

    @Schema(description = "发送者ID")
    @TableField("sender_id")
    private Long senderId;

    @Schema(description = "消息内容")
    @TableField("content")
    private String content;

    @Schema(description = "消息类型：1文本，2图片，3语音，4视频")
    @TableField("msg_type")
    private Byte msgType;

    @Schema(description = "文件URL")
    @TableField("file_url")
    private String fileUrl;

    @Schema(description = "文件大小")
    @TableField("file_size")
    private Long fileSize;

    @Schema(description = "语音/视频时长(秒)")
    @TableField("duration")
    private Integer duration;

    @Schema(description = "是否已读：0未读，1已读")
    @TableField("is_read")
    private Byte isRead;

    @Schema(description = "租户编号")
    @TableField("tenant_id")
    private Long tenantId;


}